import request from '@/utils/request'

// 修改权限点
export function putPermission(data) {
  return request({
    method: 'PUT',
    url: '/sys/permission/' + data.id,
    data
  })
}

// 获取权限点详情
export function getPermission(id) {
  return request({
    method: 'GET',
    url: '/sys/permission/' + id
  })
}

// 新增权限点
export function postPermission(data) {
  return request({
    method: 'POST',
    url: '/sys/permission',
    data
  })
}

// 删除权限点
export function delPermission(id) {
  return request({
    method: 'DELETE',
    url: '/sys/permission/' + id
  })
}

// 获取-权限点列表
export function getPermissionList() {
  return request({
    method: 'GET',
    url: '/sys/permission'
  })
}
